<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<script>
    var time=prompt('请输入您想输入的时间');
    if (time >= 6 && time <=11){
        alert('早上好');
    }else if (time >=12 && time <= 17){
        alert('中午好');
    } else if(time >=18 && time <= 22){
        alert('傍晚好');
    }else if (time >=23 || time <= 5){
        alert('深夜好');
    }
</script>
<body>

</body>
</html>